import {request} from "@/network/request";

export function getAllCommonOrder(current,size,type,data,userId){
    return request({
        url: '/user/listUserOrder/'+userId,
        method: 'get',
        params:{current,size,type,data}
    })
}

export function updateCommonUser(data,userId){
    return request({
        url: '/user/updateUser/'+userId,
        method: 'post',
        data:data,
    })
}


////////////////////////////////////////////////
//////////////用户订单修改
export function deleteUserOrder(orderId,userId){
    return request({
        url: '/user/order/delete/'+userId,
        method: 'get',
        params:{orderId}
    })
}

export function updateUserOrder(data,userId){
    return request({
        url: '/user/order/update/'+userId,
        method: 'post',
        data:data,
    })
}

export function getOrderByOrderId(orderId,userId){
    return request({
        url: '/user/order',
        method: 'get',
        params:{orderId,userId}
    })
}